package com.taotao.sso.controller;

import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

import javax.servlet.http.HttpServletRequest;

@Controller
public class PageController {
    @RequestMapping("/page/{page}")
    public String showPage(HttpServletRequest request, @PathVariable String page, String redirect){
        if (StringUtils.isNotBlank(redirect)) {
            request.setAttribute("redirect" ,redirect);
        }
        return page;
    }
}
